package com.wwb.api;

import com.wwb.sql;
import top.easyj.core.Easyj;
import top.easyj.core.component.api.Api;
import top.easyj.core.component.api.ApiInput;
import top.easyj.core.component.api.ParamMap;
import top.easyj.core.component.api.ParamString;
import top.easyj.core.exeption.ExBase;

import java.util.Date;

public class WwbApi extends ApiBase {
    @Override
    protected String path() {
        return "com/wwb";
    }

    @Override
    protected String apiGroupName() {
        return "-接口管理";
    }
    

    Api regUser = this.registerApi("用户注册", 20211016, true, new Api() {
        private ParamString id = this.param_str_required("id","用户名");
        private ParamString name = this.param_str_required("name","密码");
        private ParamString birthday = this.param_str_required("birthday","确认密码");
        private ParamString stu_remark = this.param_str_optional("stu_remark","用户头像","");
        public void regUser(ApiInput req) throws ExBase {
            ParamMap map = this.getAllParameters(req);
            dao.excuteSql(sql.wwb.regUser,map,null);
        }
        @Override
        protected void setSettings() {
        }
    });

}
